<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>我的</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, user-scalable=no, maximum-scale=1.0"/>
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<link rel="stylesheet" href="../assets/agile/css/ratchet/css/ratchet.min.css">
<link rel="stylesheet" href="../assets/agile/css/flat/flat.component.css">
<link rel="stylesheet" href="../assets/agile/css/flat/iconline.css">
<link rel="stylesheet" href="../assets/app/css/app.css" />
<script type="text/javascript" src="../script/api.js"></script>
<script type="text/javascript" src="../script/jquery.js"></script>
<script type="text/javascript" src="../script/config.js"></script>
<script type="text/javascript" src="../script/local.js"></script>
<script type="text/javascript" src="../script/common.js"></script>
<!--App自定义的css-->
<link rel="stylesheet" href="../css/bootstrap/css/bootstrap.min.css" />
<style>
body{
    background-color: #fff !important;
}
.oa-contact-cell.mui-table .mui-table-cell {
	padding: 11px 0;
	vertical-align: middle;
}
.oa-contact-avatar img {
	border-radius: 50%;
}

.oa-contact-name, oa-contact-position {
	float: left;
}

ul, li {
	margin: 0;
	padding: 0;
}

.swiper-slide img {
	height: 180px;
	min-width: 100%;
}

body {
	padding-bottom: 50px;
	font-size: 14px;
}

.hideDiv {
	display: none;
}

._dian {
	background: url(../image/dianjia_logo.png) center no-repeat;
	width: 25px;
	background-size: 25px;
}


p, ul, li, h1, h2, input, select, hr {
	background: none;
}

#max_lists li {
	width: 25%;
	over-flow: hidden;
	line-height: 80px;
	height: 80px;
}

#max_lists ul li img {
	padding-top: 10px;
}

#lists li {
	height: 55px;
}

.lh35 {
	height: 35px;
	line-height: 35px;
	text-align: center;
}

.price p {
	height: 15px;
	line-height: 15px;
}



input[placeholder], [placeholder], *[placeholder] {
	color: #ccc;
	font-size: 90%;
}

::-webkit-input-placeholder {
	color: #ccc;
	font-size: 90%;
}


._imgWidth img {
	height: 93px;
	overflow: hidden;
}
.mui-icon{
    color: white;
}
.mui-icon-black{
    color: black;

    -ms-transform:rotate(180deg); 	/* IE 9 */
    -moz-transform:rotate(180deg); 	/* Firefox */
    -webkit-transform:rotate(180deg); /* Safari 和 Chrome */
    -o-transform:rotate(180deg); 	/* Opera */
    transform:rotate(180deg);
}
.row-topheight{
    height: 25%;
}
.box-shadow-1{
    -webkit-box-shadow: 1px 1px #ffffff;
    -moz-box-shadow: 1px 1px #ffffff;
    box-shadow: 1px 1px #ffffff;
    background: #ffffff;
}

.row-top-border-right{
    border-right: 1px #D5D7DB solid
}
.row-top-text-size{
    font-size:1.5em;
}
.row-top-text-color{
    color: #FF9C00;
}
.ba-m-t{
    height: 1em;
}
.row-h3-p7{
    height:3em;padding: 0.7em;
}
.row-top-text-size{
    font-size:1.5em;
}
.l-h1{
    line-height: 1px;
}
.pHeight{
    text-align: right;
}

.img{
    width: 34px;
}
    .bg-white{
        background-color: white;
    }

.text-color-orange{
    color:#FF9C00;
}
.text-color-red{
    color: red;
}
.text-position-right{
    position: absolute;
    right: 0;
}
    .list-group{
        margin-bottom: 0.7em;
    }
</style>
</head>

<body>

<!--通用顶部-->
<div id="ios-top-box">
    <div id="header" class="bar bar-nav">
    <div class="titlebar">
    <a href="javascript:appClose('fxcenter',api);"><i class="iconfont iconline-arrow-left"></i></a>
    <h1 class="title">邀请有奖</h1>
    </div>
    </div>
</div>
<!--通用顶部结束-->


<!--    <div id="zoom" style="display:none;position:absolute;z-index:99999;left:0;top:0;width:100%;height: 100%;background:rgba(0,0,0,0.9);color:#fff;">
        <div style="float:right;margin-top:10px;margin-right:18px;background:url(../image/share.png) no-repeat;background-size:280px 100px;width:280px;height:100px;"></div>
        <div style="width:280px;float:right;margin-right:10px;">
            <div class="clear"></div>
            <h3 style="color:#999;padding:20px 0 10px 0;background:rgba(0, 0, 0, 0);font-size: 1.17em;">怎么赚钱？</h3>
            <p style="color:#999;background:rgba(0, 0, 0, 0)">1、点击本页面右上角的三点图标</p>
            <p style="color:#999;background:rgba(0, 0, 0, 0)">2、选着[发送给朋友]或[分享到朋友圈]</p>
            <p style="color:#999;background:rgba(0, 0, 0, 0)">3、经您邀请的好友，成功交易，您可获得好友消费消费额相应的佣金奖励</p>
        </div>
    </div>-->
<div class="container" style="margin-top:64px !important;">
    <div class="row row-topheight box-shadow-1">
        <div class="col-xs-6 text-center row-top-border-right">
            <div><span class="row-top-text-size">累积销售</span></div>
            <div><span class="text-color-orange agentTotalPrice">￥0</span></div>
        </div>
        <div class="col-xs-6 text-center">
            <div><span class="row-top-text-size">累积佣金</span></div>
            <div><span class="text-color-orange agentTotalPrice">￥0</span></div>
        </div>
    </div>

    
   <!-- <div class="row row-h3-p7 bg-white" id="openwindow" ontouchend="alert('221321')">
        <div class="col-xs-10 row-top-text-size l-h1">
            <img class="img"  src="../image/yun.png" style="padding-right: 10px;"><span style="line-height: 1">推广有奖</span></div>

        <div class="col-xs-2 pHeight">
            &lt;!&ndash;<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left mui-icon-black"></a>&ndash;&gt;
            <span class="glyphicon glyphicon-menu-right"></span>

        </div>
    </div>-->

    <div class="row">
        <ul class="list-group">
            <li class="list-group-item" style="height: 3em;" id="selfId">
                <div class="col-xs-8">
                    <img class="img"  src="../image/yun.png" style="padding-right: 10px;"><span style="line-height: 1">推广有奖</span>
                </div>
                <div class="col-xs-4 text-right">
                <span class="glyphicon glyphicon-menu-right"></span>
                </div>
            </li>
        </ul>
    </div>





    <div class="row">
        <div class="list-group">
            <li class="list-group-item" style="height: 3em;">
                <div class="col-xs-8">
                    <img class="img"  src="../image/mengyou.png" style="padding-right: 10px;"><span style="line-height: 1">我的盟友</span>
                </div>
                <div class="col-xs-4">
                    <span class="text-color-orange allcount">0人</span>
                </div>
            </li>


            <button  type="button" class="list-group-item fansList" style="height: 3em;" item="1">
                <div class="col-xs-10">
                    <img class="img"  src="../image/one-icon.png" style="padding-right: 10px;"><span style="line-height: 1">一级会员</span>
                    <span class="text-position-right text-color-red fansInfo_one">0人</span>
                </div>
                <div class="col-xs-2 text-right">
                    <span class="glyphicon glyphicon-menu-right"></span>
                </div>
            </button>

            <button type="button" class="list-group-item fansList" style="height: 3em;" item="2">
                <div class="col-xs-10">
                    <img class="img"  src="../image/two-icon.png" style="padding-right: 10px;"><span style="line-height: 1">二级会员</span>
                    <span class="text-position-right text-color-red fansInfo_two">0人</span>
                </div>
                <div class="col-xs-2 text-right">
                    <span class="glyphicon glyphicon-menu-right"></span>
                </div>
            </button>

            <button  type="button" class="list-group-item fansList" style="height: 3em;" item="3">
                <div class="col-xs-10">
                    <img class="img"  src="../image/three-icon.png" style="padding-right: 10px;"><span style="line-height: 1">三级会员</span>
                    <span class="text-position-right text-color-red fansInfo_three">0人</span>
                </div>
                <div class="col-xs-2 text-right">
                    <span class="glyphicon glyphicon-menu-right"></span>
                </div>
            </button>
        </div>
    </div>

    <div class="row">
        <ul class="list-group">
            <li class="list-group-item" style="height: 3em;">
                <div class="col-xs-8">
                    <img class="img"  src="../image/yongjin.png" style="padding-right: 10px;"><span style="line-height: 1">我的佣金</span>
                </div>
                <div class="col-xs-4 text-right">
                    <span class="text-color-orange price_count">0元</span>
                </div>
            </li>
            <li class="list-group-item" style="height: 3em;">
                <div class="col-xs-8">
                    <span>待清算订单佣金</span>
                </div>
                <div class="col-xs-4 text-right">
                    <span class="text-color-red priceInfo">￥0</span>
                </div>
            </li>
            <li class="list-group-item" style="height: 3em;">
                <div class="col-xs-8">
                    <span>可提现订单佣金</span>
                </div>
                <div class="col-xs-4 text-right">
                    <span class="text-color-red applyMoney">￥0</span>
                </div>
            </li>
            <li class="list-group-item" style="height: 3em;">
                <div class="col-xs-8">
                    <span>已提现订单佣金</span>
                </div>
                <div class="col-xs-4 text-right">
                    <span class="text-color-red share_price">￥0</span>
                </div>
            </li>
        </ul>
    </div>

    <div class="row">
        <ul class="list-group">
            <button type="button" class="list-group-item postapply" style="height: 3em;">
                <div class="col-xs-8">
                    申请提现
                </div>
                <div class="col-xs-4 text-right">
                    <span class="glyphicon glyphicon-menu-right"></span>
                </div>

                </button>
        </ul>
    </div>



</div>
<script>
apiready = function(){
	
		var wxfun = document.getElementById('selfId');
		wxfun.onclick = function(){
			api.openWin({
				name:'invitation',
				url:'./invitation.html',
				reload:true
			});
		};
	
	var userinfo = getUserinfo();
	if(!userinfo){
		$.PageDialog.fail('请登录用户');
		return;
	}else{
		
		$('.fansList').click(function(){
			var level = $(this).attr('item');
			localData.set('level_id',level);
			randomSwitchBtn('allFansinfo',api);
		});
		
		$('.postapply').click(function(){
			randomSwitchBtn('postapply',api);
		});
		
		GetJPData(config.url+'/app.php?act=fxcenter&uid='+userinfo.uid,{},function(data){
			if(data['status'] == 1){
				$('.allcount').text((data['allcount']).toString()+'人');
				$('.price_count').text('￥'+(data['priceInfo']['count']?data['priceInfo']['count']:0).toString());
				$('.agentTotalPrice').text('￥'+(data['priceInfo']['count']?data['priceInfo']['count']:0).toString());
				$('.fansInfo').text((data['fansinfo']['all']?data['fansinfo']['all']:0).toString()+'人');
				$('.fansInfo_one').text((data['oneLevel']?data['oneLevel']:0).toString()+'人');
				$('.fansInfo_two').text((data['twoLevel']?data['twoLevel']:0).toString()+'人');
				$('.fansInfo_three').text((data['threeLevel']?data['threeLevel']:0).toString()+'人');
				$('.priceInfo').text('￥'+data['priceInfo']['wait']);
				$('.applyMoney').text('￥'+(data['applyMoney']?data['applyMoney']:0).toString());
				$('.share_price').text('￥'+(data['sharePrice']?data['sharePrice']:0).toString());
			}else{
				$.PageDialog.fail(data['msg']);
			}
		});
		
		
			var sids = setInterval(function(){
				if (localData.set('zok')) {
					GetJPData(config.url + '/app.php?act=fxcenter&uid=' + userinfo.uid, {}, function(data){
						if (data['status'] == 1) {
							$('.allcount').text((data['allcount']).toString() + '人');
							$('.price_count').text('￥' + (data['priceInfo']['count'] ? data['priceInfo']['count'] : 0).toString());
							$('.agentTotalPrice').text('￥' + (data['priceInfo']['count'] ? data['priceInfo']['count'] : 0).toString());
							$('.fansInfo').text((data['fansinfo']['all'] ? data['fansinfo']['all'] : 0).toString() + '人');
							$('.fansInfo_one').text((data['oneLevel'] ? data['oneLevel'] : 0).toString() + '人');
							$('.fansInfo_two').text((data['twoLevel'] ? data['twoLevel'] : 0).toString() + '人');
							$('.fansInfo_three').text((data['threeLevel'] ? data['threeLevel'] : 0).toString() + '人');
							$('.priceInfo').text('￥' + data['priceInfo']['wait']);
							$('.applyMoney').text('￥' + (data['applyMoney'] ? data['applyMoney'] : 0).toString());
							$('.share_price').text('￥' + (data['sharePrice'] ? data['sharePrice'] : 0).toString());
						}else {
							//
						}
					});
					clearInterval(sids);
				}
			},1000);
	}
};

</script>
</body>
</html>